﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Data;

namespace AliCMS.SubscribeModule
{
    public interface IInstanceConfig : IObject
    {
        Dictionary<string, string> GetBasicSettings();
        void SetBasicSettings(Dictionary<string, string> value);

        void Save();

        void CheckAndContinue(DataRow task);
        void SyncIndustry();
        void SyncRegion();
    }
    public interface IRegion : IDbObject
    {
        void Move(int from, int to);
    }
    public interface IIndustry : IDbObject
    {
        void Move(int from, int to);
    }
    public interface ICompany : IDbObject
    {
        void Recycle(int id);
        void Recover(int id);

        void Replace(string property, string from, string to);

        bool IsRunning();
        void Stop();
        void OnCollectComplete(object state);
    }
    public interface IPerson : IDbObject
    {
        void Recycle(int id);
        void Recover(int id);
    }
    public interface IMail : IDbObject
    {
        void Recycle(int id);
        void Recover(int id);
        
        void StartExecute(int id);
        void StartExecute(DataRow task);
        void StopExecute(int id);
        bool IsRunning(int id);
    }
    public interface IMailSender : IDbObject
    {
        void Recycle(int id);
        void Recover(int id);
        void Move(int from, int to);

        DataTable SenderList();

        void Sort(string creator);
    }
    public interface ITag : IDbObject
    {
    }
    namespace Company
    {
        public interface ITag : IDbObject
        {
            void Delete(Guid companyID, Guid tagID);
        }
    }
    namespace Person
    {
        public interface ITag : IDbObject
        {
            void Delete(Guid personID, Guid tagID);
        }
    }
    namespace Mail
    {
        public interface ILog : IDbObject
        {
        }
    }
}
